Portable Multithreading-The Signal Stack Trick for User-Space Thread Creation

نویسنده

  • Ralf S. Engelschall
چکیده

This paper describes a pragmatic but portable fallback approach for creating and dispatching between the machine contexts of multiple threads of execution on Unix systems that lack a dedicated user-space context switching facility. Such a fallback approach for implementing machine contexts is a vital part of a user-space multithreading environment, if it has to achieve maximum portability across a wide range of Unix flavors. The approach is entirely based on standard Unix system facilities and ANSI-C language features and especially does not require any assembly code or platform specific tricks at all. The most interesting issue is the technique of creating the machine context for threads, which this paper explains in detail. The described approach closely follows the algorithm as implemented by the author for the popular user-space multithreading library GNU Portable Threads (GNU Pth, [25]) which this way quickly gained the status of one of the most portable user-space multithreading libraries.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Multithreading Languages

It is di cult to map the execution model of multithreading languages (languages which support ne-grain dynamic thread creation) onto the single stack execution model of C. Consequently, previous work on e cient multithreading uses elaborate frame formats and allocation strategy, with compilers customized for them. This paper presents an alternative cost-e ective implementation strategy for mult...

متن کامل

Fine - grain Multithreading with Minimal Compiler

It is di cult to map the execution model of multithreading languages (languages which support ne-grain dynamic thread creation) onto the single stack execution model of C. Consequently, previous work on e cient multithreading uses elaborate frame formats and allocation strategy, with compilers customized for them. This paper presents an alternative cost-e ective implementation strategy for mult...

متن کامل

Runtime Mechanisms for E cient Dynamic

High performance on distributed memory machines for programming models with dynamic thread creation and multithreading requires eecient thread management and communication. Traditional mul-tithreading runtimes, consisting of few general-purpose, bundled mechanisms that assume minimal compiler and hardware support, are suitable for computations involving coarse-grained threads but provide low ee...

متن کامل

Performance Evaluation and Optimization of A Custom Native Linux Threads Library

The current SpecC simulator utilizes PosixThreads, QuickThreads or a custom native Linux thread library named LiteThreads to perform thread manipulation. While QuickThreads is very efficient as a user-level thread library and PosixThreads supports multithreading and the parallel simulator, the proposed LiteThreads library combines the advantages of both thread libraries and aimes to achieve a s...

متن کامل

A Multithreading Platform for Multimedia Applications

Complex multimedia applications have diverse resource and timing requirements. A platform for building such programs therefore should supply the developer with mechanisms for managing concurrency, communication, and real-time constraints but should remain flexible with regard to scheduling policies and interaction models. We have developed such a platform consisting of a user-level threads pack...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2000